﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;

namespace dzs.Web.tenderExpert
{
    public partial class PrintExpert : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                if (!string.IsNullOrEmpty(Request["tenderNum"]))
                {
                    Bind(Request["tenderNum"]);
                }

               
            }
        }

        private void Bind(string num)
        {
            Maticsoft.BLL.expertConfirm excm = new Maticsoft.BLL.expertConfirm();

            DataSet ds = excm.GetList(" status = 1  and  tenderNum='" + num + "'");

            //DataSet ds = excm.GetList(" status = 1 ");

            if (ds.Tables[0].Rows.Count > 0)
            {
                DataTable dt = ds.Tables[0].Clone();

                string superviseName = "";//纪委监督人
                string randomName = "";
                string tenderNum = "";
                string projectname = "";

                DataRow row = ds.Tables[0].Rows[0];
                superviseName = row["superviseName"].ToString();
                randomName = row["randomName"].ToString();
                tenderNum = row["tenderNum"].ToString();
                projectname = row["projectname"].ToString();

                this.lbl_cqr.Text = randomName;
                this.lbl_jdr.Text = superviseName;
                this.lbl_projectName.Text = projectname;
                this.lbl_zbbh.Text = tenderNum;
                this.lbl_zbbht.Text = tenderNum;

                this.GridView1.DataSource = ds;
                this.GridView1.DataBind();

                //this.gridView.DataSource = dt;
                //this.gridView.DataBind();
            }
           
        }
    }
}